<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <link rel="stylesheet" type="text/css" href="/layui/css/layui.css">
    <link rel="stylesheet" href="/css/orderCss/viewcourses.css">
</head>
<body >
<div>

<!--    <form id="_form" method="post" action="/order/intermediate/viewcourses">-->
<!--        <input type="hidden" name="orderId" value="" />-->
<!--        <a onclick="document.getElementById('_form').submit();" id="sp"></a>-->
<!--    </form>-->

    <table class="layui-table">
        <colgroup>
            <col width="25%">
            <col  width="25%">
            <col width="25%">
            <col width="25%">
        </colgroup>
        <thead>
        <tr>
            <th>订单编号</th>
            <th>课程名称</th>
            <th>用户账号</th>
            <th>订单状态</th>
        </tr>
        </thead>
        <tbody>
        <tr>
            <td >
                <p th:text="${viewcourses.orderReference}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.curriculumName}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.userAccount}"></p>
            </td>
            <td >
                <div th:switch="${viewcourses.orderStatus}">
                    <p th:case="2">待付款</p>
                    <p th:case="3">已付款</p>
                    <p th:case="4">待发货</p>
                    <p th:case="5">已发货</p>
                    <p th:case="6">已签收</p>
                    <p th:case="7">退货申请</p>
                    <p th:case="8">退货中</p>
                    <p th:case="9">已退货</p>
                    <p th:case="10">取消交易</p>
                    <p th:case="11">拒绝退货</p>
                    <p th:case="12">待评论</p>
                    <p th:case="13">已完成</p>
                </div>

            </td>
        </tr>
        </tbody>
    </table>
    <table class="layui-table">
        <colgroup>
            <col width="25%">
            <col  width="25%">
            <col width="25%">
            <col width="25%">
        </colgroup>
        <thead>
        <tr>
            <th>支付方式</th>
            <th>订单来源</th>
            <th>订单类型</th>
            <th></th>
        </tr>
        </thead>
        <tbody>
        <tr>
            <td >
                <div th:switch="${viewcourses.orderPayment}">
                    <p th:case="1">微信支付</p>
                    <p th:case="2">余额支付</p>
                    <p th:case="3">支付宝支付</p>
                    <p th:case="4">未支付</p>
                </div>
            </td>
            <td >
                <div th:switch="${viewcourses.orderSource}">
                    <p th:case="2">小程序</p>
                    <p th:case="3">APP</p>
                </div>
            </td>
            <td >
                <p th:text="${viewcourses.orderType}"></p>
            </td>
            <td></td>
        </tr>
        </tbody>
    </table>
</div>
<div>
    <table class="layui-table">
        <colgroup>
            <col width="25%">
            <col  width="25%">
            <col width="25%">
        </colgroup>
        <thead>
        <tr>
            <th>用户名称</th>
            <th>手机号码</th>
            <th>邮箱</th>
        </tr>
        </thead>
        <tbody>
        <tr>
            <td >
                <p th:text="${viewcourses.userNickname}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.userPhone}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.userEmail}"></p>
            </td>
        </tr>
        </tbody>
    </table>
</div>
<div>
    <table class="layui-table">
        <thead>
        <tr>
            <th style="width: 150px;">课程图片</th>
            <th>课程名称</th>
            <th>课程分类</th>
            <th>课程价格</th>
            <th>优惠金额</th>
            <th>实付金额</th>
        </tr>
        </thead>
        <tbody>
        <tr>
            <td>
                    <img  th:src="${viewcourses.curriculumPictureurl}" style="width: 150px;" >
            </td>
            <td >
                <p th:text="${viewcourses.curriculumName}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.classificationName}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.curriculumPresentPrice}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.orderDiscounts}"></p>
            </td>
            <td >
                <p th:text="${viewcourses.orderPocket}"></p>
            </td>
        </tr>
        </tbody>
    </table>
</div>
<script src="/layui/jquery-3.6.0.js"></script>
<script src="/layui/layui.js"></script>
<script src="/js/order/viewcourses.js"></script>
</body>
</html>